/**
 *
 * @author DnD Binary Source
 */
package binarysource;

import org.jdesktop.application.Action;

public class CreditsBox extends javax.swing.JDialog {

    public CreditsBox(java.awt.Frame parent) {
        super(parent);
        initComponents();
        getRootPane().setDefaultButton(btnClose);
    }

    @Action
    public void closeCreditsBox() {
        dispose();
    }

    /** This method is called from within the constructor to
     * initialize the form.
     * WARNING: Do NOT modify this code. The content of this method is
     * always regenerated by the Form Editor.
     */
    // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
    private void initComponents() {

        javax.swing.JLabel logo = new javax.swing.JLabel();
        javax.swing.JLabel labTitle = new javax.swing.JLabel();
        javax.swing.JLabel labDescription = new javax.swing.JLabel();
        btnClose = new javax.swing.JButton();

        setDefaultCloseOperation(javax.swing.WindowConstants.DISPOSE_ON_CLOSE);
        org.jdesktop.application.ResourceMap resourceMap = org.jdesktop.application.Application.getInstance().getContext().getResourceMap(CreditsBox.class);
        setTitle(resourceMap.getString("aboutBox.title")); // NOI18N
        setBackground(resourceMap.getColor("aboutBox.background")); // NOI18N
        setIconImage(null);
        setModal(true);
        setName("aboutBox"); // NOI18N
        setResizable(false);

        logo.setIcon(resourceMap.getIcon("logo.icon")); // NOI18N
        logo.setName("logo"); // NOI18N

        labTitle.setFont(labTitle.getFont().deriveFont(labTitle.getFont().getStyle() | java.awt.Font.BOLD, labTitle.getFont().getSize()+4));
        labTitle.setText(resourceMap.getString("labTitle.text")); // NOI18N
        labTitle.setName("labTitle"); // NOI18N

        labDescription.setText(resourceMap.getString("labDescription.text")); // NOI18N
        labDescription.setName("labDescription"); // NOI18N

        javax.swing.ActionMap actionMap = org.jdesktop.application.Application.getInstance().getContext().getActionMap(CreditsBox.class, this);
        btnClose.setAction(actionMap.get("quit")); // NOI18N
        btnClose.setText(resourceMap.getString("btnClose.text")); // NOI18N
        btnClose.setToolTipText(resourceMap.getString("btnClose.toolTipText")); // NOI18N
        btnClose.setName("btnClose"); // NOI18N

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(getContentPane());
        getContentPane().setLayout(layout);
        layout.setHorizontalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addGroup(layout.createSequentialGroup()
                .addComponent(logo)
                .addGap(18, 18, 18)
                .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING)
                    .addComponent(labTitle, javax.swing.GroupLayout.Alignment.LEADING)
                    .addGroup(javax.swing.GroupLayout.Alignment.LEADING, layout.createSequentialGroup()
                        .addGap(208, 208, 208)
                        .addComponent(btnClose, javax.swing.GroupLayout.PREFERRED_SIZE, 54, javax.swing.GroupLayout.PREFERRED_SIZE))
                    .addComponent(labDescription, javax.swing.GroupLayout.PREFERRED_SIZE, 262, javax.swing.GroupLayout.PREFERRED_SIZE))
                .addContainerGap(10, Short.MAX_VALUE))
        );
        layout.setVerticalGroup(
            layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
            .addComponent(logo, javax.swing.GroupLayout.PREFERRED_SIZE, 178, Short.MAX_VALUE)
            .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, layout.createSequentialGroup()
                .addContainerGap()
                .addComponent(labTitle)
                .addGap(18, 18, 18)
                .addComponent(labDescription, javax.swing.GroupLayout.PREFERRED_SIZE, 43, javax.swing.GroupLayout.PREFERRED_SIZE)
                .addGap(53, 53, 53)
                .addComponent(btnClose)
                .addContainerGap())
        );

        getAccessibleContext().setAccessibleDescription(resourceMap.getString("aboutBox.AccessibleContext.accessibleDescription")); // NOI18N

        pack();
    }// </editor-fold>//GEN-END:initComponents

    // Variables declaration - do not modify//GEN-BEGIN:variables
    private javax.swing.JButton btnClose;
    // End of variables declaration//GEN-END:variables

}
